/**
 * 
 */
package org.lex.net.ping;

/**
 * @author Daniel Liu
 */
class WindowsPing extends Ping {
	protected WindowsPing(String host, int packetSize, int count) {
		super(host, packetSize, count);
	}

	@Override
	protected String[] createPingCommand() {
		String[] command = new String[6];
		command[0] = "ping";
		command[1] = "-n";
		command[2] = Integer.toString(this.getCount());
		command[3] = "-l ";
		command[4] = Integer.toString(this.getPacketSize());
		command[5] = this.getHost();
		return command;
	}

	@Override
	protected PingEvent parsePingReply(String line) {
		PingEvent e = new PingEvent(line);
		return e;
	}
}
